/**
 * JEg_E
 * 
 * @param {String} sedir SEt@C̏ꏊ
 */
task CountDown( sedir ){
	let count = 9;
	
	loop{
		if( count == GetTimer() ){
			PlaySE( sedir );
			count -= 1;
		}
		yield;
	}
}

/**
 * 蔻o^+{oA
 * 
 * @param {Integer} hita        eɑ΂铖蔻
 * @param {Integer} hitb        @ɑ΂铖蔻
 * @param {Boolean} bombbarrier {oẢ
 * @param {Integer} hitwait     蔻o^܂ł̑҂
 */
task SetCollisionEx( hita, hitb, bombbarrier, hitwait ){
	let cnt = 0;
	
	loop{
		if( !( OnBomb() && bombbarrier ) && cnt >= hitwait ){
			SetCollisionA( GetX(), GetY(), hita );
		}
		
		SetCollisionB( GetX(), GetY(), hitb );
		
		cnt += 1;
		
		yield;
	}
}

/**
 * CreateItemg
 * 
 * @param {Integer} type 
 * @param {Integer} rnd  Ԃ͈
 * @param {Integer} num  Ƃ
 */
function CreateItemEx( type, rnd, num ){
	let rrad = 0;
	let rang = 0;
	let bx = 0;
	let by = 0;
	
	loop( num ){
		rrad = rand( 0, rnd );
		rang = rand( 0, 360 );
		bx = GetX() + cos( rang ) * rrad;
		by = GetY() + sin( rang ) * rrad;
		CreateItem( type, bx, by );
	}
}